import Page from "$UI/wxsys/comps/reactContainer/page/Page"; 


export default class IndexPage extends Page {
    constructor(...args) {/*{{{*/this.comp = require("_comp").default;this._e= require("_event_").default;/*为代码提示动态插入的辅助代码,不要删除}}}*/super(...args); }



    OnOKClick = (event) => {

        let list = []
        this.comp('restData0').each((item)=>{
            console.log(item.row)
            if (item.row.checked){
                list.push(item.row)
            }
        })
        if (list.length > 0){
            wx.setStorage({
                key: 'dialogSelectShixi',
                data: list
            })
            this.comp('commonOperation').close()
        }else{
            this.hint('请选择')
        }
	}

    onButton0OnClick = (event) => {
        this.comp('commonOperation').close()
	}


    onCheckbox0OnChange = () => {
        //event.stopPraprogation()

        var comp = this.comp('restData0')
        //comp.to(comp.getCurrentRow())
        setTimeout(function(){
            
            comp.current.checked = (comp.current.checked=='1'?null:'1')
            console.log('now',comp.current.checked)
        },0)
        
	}

    onList0OnRowClick = (event/*{{{*/=this._e.List_onRowClick/*}}}*/) => {
        this.onCheckbox0OnChange();
	}


    
    onPrevent_defaultClick = ({e}) => {
		e.stopPropagation()
	}
}